package ExceptionDemo;

import java.util.logging.Logger;

public class LoggerUtil {
    private static final Logger logger = Logger.getLogger(LoggerUtil.class.getName());

    public static void logTransfer(String from, String to, double amount) {
        logger.info("执行转账操作: 从 " + from + " 转账 " + amount + " 到 " + to);
    }

    public static void logError(String message, Throwable throwable) {
        logger.severe(message + " 异常信息: " + throwable.getMessage());
    }
}